// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import Layout from './components/layout'
import  IndexPage from './pages/index'
// 引入路由文件
import VueRouter from 'vue-router'
// 使用路由文件
Vue.use(VueRouter)
// 实例化一个路由对象
let router = new VueRouter({
  mode:'history',
  routes:[
    {
      path:'/',
      component : IndexPage
      
    }
  ]
})
Vue.config.productionTip = false

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  components: { Layout  },
  template: '<Layout/>'
})
